package org.inspursc.s0517.health.common.entity;

import lombok.Data;
import org.hibernate.annotations.DynamicUpdate;

import javax.persistence.*;

/**
 * 系统权限
 */
@Data
@Entity(name = "sys_permission")
@DynamicUpdate
public class SysPermission  extends AbstractIdEntity {



    /**
     *名称
     */
    @Column(name = "name")
    private String name;

    /**
     * 描述
     */
    @Column(name = "description")
    private String description;

    /**
     * URL
     */
    @Column(name = "url")
    private String url;

    /**
     * 父ID
     */
    @Column(name = "pid")
    private Integer pid;


    @Override
    public String toString() {
        return "SysPermission{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", description='" + description + '\'' +
                ", url='" + url + '\'' +
                ", pid=" + pid +
                '}';
    }
}
